function initInfoWindow(){
    var infoDiv = '<div id="trackPopUp" class="trackPopUp" style="z-index:999;position:absolute;">'+
        '<div id="trackPopUpContent" class="leaflet-popup" style="top:5px;left:0; ">'+
        '<a class="leaflet-popup-close-button" href="#">×</a>'+
        '<div class="leaflet-popup-content-wrapper">'+
        '<div id="trackPopUpLink" class="leaflet-popup-content"></div>'+
        '</div>'+
        '<div class="leaflet-popup-tip-container">'+
        '<div class="leaflet-popup-tip"></div>'+
        '</div>'+
        '</div>'+
        '</div>';
    $("#cesiumContainer").append(infoDiv);
}

function infoWindow(obj) {
    var cartesian = getPickPositionGlobe(obj.position); // 可以拾取球皮和模型 不在球上则无拾取点
    if (!cartesian) return;
    $(".cesium-selection-wrapper").show();
    $('#trackPopUpLink').empty();
    $('#trackPopUpLink').append(obj.content);

    function positionPopUp (c) {
        //var x = c.x - ($('#trackPopUpContent').width()) / 2;
        //var y = c.y - ($('#trackPopUpContent').height());
        // $('#trackPopUpContent').css('transform', 'translate3d(' + x + 'px, ' + y + 'px, 0)');

        var bubble = document.getElementById("trackPopUp");
        //设置弹出框位置
        bubble.style.left = parseInt(obj.position.x)+"px";
        var divheight = bubble.offsetHeight;
        var divy = parseInt(obj.position.y);//50px为.bubble:after--20x50
        bubble.style.top = divy + "px";

        //_pm_position = { x: c.x, y: c.y }

    }
    $('#trackPopUp').show();
    positionPopUp(obj.position);
    //if (movePositionEventListener) { // 先销毁上次的监听
    // movePositionEventListener = movePositionEventListener && movePositionEventListener();
    // }
    // 每一帧渲染结束后，对位置进行更新
    movePositionEventListener = viewer.scene.postRender.addEventListener(function () {
        var screen = Cesium.SceneTransforms.wgs84ToWindowCoordinates(viewer.scene, cartesian);
        if ((obj.position.x !== screen.x) || (obj.position.y !== screen.y)) {
            positionPopUp(screen);
            obj.position = screen;
        }
    });

    $('.leaflet-popup-close-button').click(function() {
        $('#trackPopUp').hide();
        $('#trackPopUpLink').empty();
        $(".cesium-selection-wrapper").hide();
        if (!handler3D) { // 如果无handler3D操作，移除当前的trackPopUp
            $("#trackPopUp").remove();
        }
        if (movePositionEventListener) {
            movePositionEventListener = movePositionEventListener && movePositionEventListener();
        }
    });
}